﻿<%@ Page Title="" Language="C#" MasterPageFile="~/admin/masAdmin.master" AutoEventWireup="true" CodeFile="CustomerDetail.aspx.cs" Inherits="admin_CustomerDetail" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="pagename" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="content" runat="Server">
    <div class="content-box-header">
        <h3>
            Customer Detail
        </h3>
    </div>
    <!-- End .content-box-header -->
    <div class="content-box-content">
        <div class="tab-content default-tab" id="tab1">
            <table border="0" cellpadding="0" cellspacing="0" class="table100">
                <tr>
                    <td colspan="2">
                        <span class="commentRequireInputText">
                            <%=Resources.Resource.LBL_REQUIREMENT%>
                        </span>
                    </td>
                </tr>
                <tr>
                    <td>
                    </td>
                    <td align="left">
                        <asp:ValidationSummary ID="vsumForm" runat="server" ShowMessageBox="true" ShowSummary="false"
                            CssClass="errorMessage" />
                        <asp:Label ID="lblErrorMessage" runat="server" CssClass="errorMessage"></asp:Label>
                    </td>
                </tr>
                <tr>
                    <td width="150px" align="right">
                        Name(<span class="commentRequireInputText">*</span>):
                    </td>
                    <td>
                        <asp:TextBox ID="txtName" MaxLength="50" Width="400px" runat="server">
                        </asp:TextBox>
                        <asp:RequiredFieldValidator ID="reqName" runat="server" EnableClientScript="true"
                            CssClass="errorMessage" ErrorMessage="Title is require" Display="Dynamic" ControlToValidate="txtName">*</asp:RequiredFieldValidator>
                    </td>
                </tr>              
                <tr>
                    <td align="right">
                        Active:
                    </td>
                    <td>
                        <asp:CheckBox ID="chkIsActive" runat="server" Checked="true" />
                    </td>
                </tr>
                <tr>
                    <td>
                    </td>
                    <td style="height: 40px;" valign="bottom">
                        <asp:Button ID="btnSave" runat="server" CssClass="button" Text="Save" OnClick="btnSave_Click"
                            CausesValidation="true" />
                        <asp:Button ID="btnCancel" runat="server" CssClass="button" Text="Cancel" OnClick="btnCancel_Click"
                            CausesValidation="false" />
                    </td>
                </tr>
            </table>
        </div>
    </div>
    <input type="hidden" value="" runat="server" id="hidCategoryIDSelect" />
     <script language="JavaScript" type="text/javascript">

         var ns6 = document.getElementById && !document.all ? 1 : 0

         var head = "display:''"
         var department = ''
         function SelectCateName(id) {
             var chk = document.getElementById('chkCategory_' + id);
             if (chk) {
                 var status = !chk.checked;
                 if (status) {
                     chk.checked = status;
                     CheckCategoryItem(id, status);
                 }
             }
         }
         function expandit(objid) {
             department = document.getElementById('SPAN' + objid).style;
             img = document.getElementById('IMG' + objid);
             fld = document.getElementById('FLD' + objid);

             if (department.display == "none") {
                 department.display = "block"
                 img.src = img.src.replace(/plus/i, "minus");
                 fld.src = fld.src.replace(/plus/i, "minus");
             } else {
                 department.display = "none"
                 img.src = img.src.replace(/minus/i, "plus");
                 fld.src = fld.src.replace(/minus/i, "plus");
             }
         }
         function CheckCategoryItem(id, status) {

//             var idSelect = document.getElementById('<%=hidCategoryIDSelect.ClientID %>').value;
//             if (status) {
//                 idSelect += id + ';';
//             }
//             else idSelect = idSelect.replace(id + ';', '');
             document.getElementById('<%=hidCategoryIDSelect.ClientID %>').value = id;

         }
         function CheckCate() {
             var arr = new Array();
             var id = document.getElementById('<%=hidCategoryIDSelect.ClientID %>').value;
             arr = id.split(';');
             if (arr.length > 1) {
                 for (var i = 0; i < arr.length; i++) {
                     var ctr = document.getElementById('chkCategory_' + arr[i].toString());
                     if (ctr)
                         ctr.checked = true;
                 }
             }
         }
    </script>
</asp:Content>

